import 'package:dk_flutter_base/dk_ui.dart';

class HouseSourceListBean {
  int pageCount;
  int totalCount;
  List<HouseSourceBean> houseTask;
  HouseSourceListBean({this.pageCount,this.totalCount,this.houseTask});
  HouseSourceListBean.fromJson(Map<String, dynamic> json) {

    this.pageCount = json['pageCount'];
    this.totalCount = json['totalCount'];
    this.houseTask = (json['houseTask'] as List)!=null?(json['houseTask'] as List).map((i) => HouseSourceBean.fromJson(i)).toList():null;
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['pageCount'] = this.pageCount;
    data['totalCount'] = this.totalCount;
    data['houseTask'] = this.houseTask != null?this.houseTask.map((i) => i.toJson()).toList():null;
    return data;
  }
}

class CommunitySearchBean {
  int     xiaoquId;
  String  name;
  CommunitySearchBean(this.name,this.xiaoquId);
  CommunitySearchBean.fromJson(Map<String, dynamic> json) {
    this.xiaoquId = json['xiaoquId'];
    this.name = json['name'];
  }
  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['xiaoquId'] = this.xiaoquId;
    data['name'] = this.name;
    return data;
  }
}

class HouseSourceBean {

  int    id;
  double area;
  int    price;
  int    roomNums;
  String createdAt;
  String updatedAt;
  String houseStatus;
  String dealerName;
  String createName;
  String communityName;
  String referenceSource;
  String storey;

  HouseSourceBean({this.id,this.area,this.price,this.roomNums,this.createdAt,this.updatedAt,this.houseStatus,
    this.dealerName,this.createName,this.communityName,this.referenceSource, this.storey});
  HouseSourceBean.fromJson(Map<String, dynamic> json) {

    this.id = json['id'];
    this.area = json['area'];
    this.price = json['price'];
    this.roomNums = json['roomNums'];
    this.createdAt =  json['createdAt'];
    this.updatedAt =  json['updatedAt'];
    this.houseStatus =  json['houseStatus'];
    this.dealerName =  json['dealerName'];
    this.createName = json['createName'];
    this.communityName =  json['communityName'];
    this.referenceSource =  json['referenceSource'];
    this.storey = json['storey'];
  }
  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['id'] = this.id;
    data['area'] = this.area;
    data['price'] = this.price;
    data['roomNums'] = this.roomNums;
    data['createdAt'] = this.createdAt;
    data['updatedAt'] = this.updatedAt;
    data['houseStatus'] = this.houseStatus;
    data['dealerName'] = this.dealerName;
    data['createName'] = this.createName;
    data['communityName'] = this.communityName;
    data['referenceSource'] = this.referenceSource;
    data['storey'] = this.storey;
    return data;
  }
}
